Release 10.1A: OpenEdge Development:
Programming Interfaces
Specifying field lists in the 4GL
You can specify a field list in two different 4GL contexts:
This is the syntax for specifying a field list in all cases:
The
record–bufnamereference specifies the table buffer you are using for the fetch, and afieldreference specifies a field in the table. Iffieldis an array reference, the whole array is fetched. TheFIELDSform lists the fields included in the fetch, and theEXCEPTform lists the fields excluded from the fetch.FIELDSwithoutfieldreferences fetches enough information to return theROWIDof a record, andEXCEPTwithoutfieldreferences orrecord–bufnamealone fetches a complete record.Queries versus record selection blocks
For a query, you must specify the field lists in the
DEFINEQUERYstatement, not the Record phrase of theOPENQUERYstatement. Thus, the following two procedures,i-fldls1.pandi-fldls2.p, are functionally equivalent:
Shared queries
If you specify field lists in a
NEWSHAREDquery, the matchingSHAREDquery definitions in external procedures only have to include theFIELDSorEXCEPTkeyword as a minimum field list reference. The complete field list is optional in theSHAREDquery definitions, but required in theNEWSHAREDquery definition.However, Progress raises the
ERRORcondition when you run a procedure with aSHAREDquery if you:
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |